****This code completes the analyses on the experimental data for the paper,
****"Affective polarization and Misinformation"
***Libby Jenke
**December 14, 2022
*Results in the paper are generated using Stata 14.2 for Mac

clear all

*cd " "
use ~/Data/expData_rep.dta

***Misinformation descriptive statistics
*Table 6
program misinfcalc
	ttest misinf`1', by(dem)
end
misinfcalc 1
misinfcalc 2
misinfcalc 3
misinfcalc 4

program misinfcalc2
	tab misinf`1'
end
misinfcalc2 1
misinfcalc2 2
misinfcalc2 3
misinfcalc2 4

program misinfcalc3
	sum conf`1' if misinf`1'>0.5
end
misinfcalc3 1
misinfcalc3 2
misinfcalc3 3
misinfcalc3 4

***Table 7
*In-party-congruent misinformation
sem (partyrate <- treat) (misinf_in <- partyrate treat), vce(bootstrap,reps(1000))
estat teffects

*Out-party-congruent misinformation
sem (partyrate <- treat) (misinf_out <- partyrate treat), vce(bootstrap,reps(1000))
estat teffects



